#import <Foundation/Foundation.h>
#import "ConstansDefine.h"
@protocol WebRequestDelegate<NSObject>

@optional

-(void) processRequestResult:(BOOL)result;

@end



@interface WebRequest: NSObject {
	NSMutableData *receivedData;
	NSURLConnection *theConnection;
	id<WebRequestDelegate> _delegate;
}

@property(nonatomic, assign) id<WebRequestDelegate> delegate;

-(void) requestTo:(NSString*)uri withBody:(NSString*)httpBody;
-(void) processResult:(NSDictionary*)result;
-(void) notifyIfConnectionFail:(NSError*)error;
@end
